﻿@using Microsoft.AspNetCore.Components.Forms
<EditForm Enhance EditContext="_editContext" method="POST" OnValidSubmit="() => _submitted = true" FormName="someform">
    @if(BindingContext == null)
    {
        <AntiforgeryToken />
    }
    <input id="send" type="submit" value="Send" />
</EditForm>

@if (_submitted)
{
    <p id="pass">Form submitted!</p>
}

@code{
    [CascadingParameter] public FormMappingContext BindingContext { get; set; }

    bool _submitted = false;
    EditContext _editContext = new EditContext(new object());
}
